<template>
  <el-main>
    <el-table
        :data="tableData"
        style="width: 100%">
      <el-table-column
          prop="userName"
          label="用户"
          width="180">
      </el-table-column>
      <el-table-column
          prop="dept.deptName"
          label="部门"
          width="180">
      </el-table-column>
      <el-table-column
          prop="createTime"
          label="创建时间">
      </el-table-column>
    </el-table>
  </el-main>
</template>
<script>

  export default {
    data() {
      return {
        tableData:[]
      }
    },
    methods:{

    },
    created() {
      this.axios.get('http://localhost:8080/s2/user/list').then(res=>{
        console.log(res.data);
        this.tableData=res.data.data;

      })
    }
  }

</script>
